﻿using System;
using System.ComponentModel.DataAnnotations;

namespace CodeCamp.Infrastructure.Extensions
{
    public class EmailAttribute : RegularExpressionAttribute
    {
        public EmailAttribute()
            : base("^[a-zA-Z0-9_\\+-]+(\\.[a-zA-Z0-9_\\+-]+)*@[a-zA-Z0-9]+(\\.[a-zA-Z0-9-]+)*\\.([a-z]{2,4})$")
        {
        }
    }
}